<head>
    <meta http-equiv="Content-Type" content="text/html; charset=UTF-8" />
    <style>
        form {
            margin: 28px 0 0px 0px;
            width:630px;
        }
        form input {
            border:#474747 1px solid;
            background:#2f2f2f;
            font-size:12px;
            font-family:Arial, Helvetica, sans-serif;
            color:#fff;
            padding:4px 10px 5px 10px;
            outline: medium none;
            width:256px;
            height:17px;
            float:left;
        }
        .input2{    
            height:28px;
            width: 156px;
        }
        form label {
            position:relative;
            display: block;
            min-height:34px;
            overflow:hidden;
        }
        .btns {
            width:156px;
            text-align:right;
            overflow:hidden;
            border-top:#2e2e2e 1px solid;
            margin-left:90px;
            margin-top:14px;
            padding-top:10px;
        }
        form label strong {
            float:left;
            text-align:right;
            display:block;
            padding-top:4px;
            line-height:18px;
            width:120px;
            font-weight:normal;
            margin-right:12px;
            white-space:nowrap;
        }
        .correction{
            border:none;
            background:none;
            width:500px;
        }
        .correction2{
            width:30px;
        }
    </style>
</head>
<div class="grid_2 prefix_1"><br></div>
<div class="grid_12 prefix_1">
    <h2 class="h2 top-3">Datos del perfil</h2>
    <?php echo form_open('user/actualizar'); ?>
    <fieldset><legend class="bold">Datos Obligatorios:</legend>
        <label><strong>Usuario:</strong>
            <input type="text" name="username" id="username" value="<?php echo $username; ?>" readonly required>
            <strong class="clear"></strong></label>
        <label><strong>Contraseña vieja:</strong>
            <input type="password" name="password" id="password" value="" required>
            <strong class="clear"></strong></label>
        <label><strong>Contraseña nueva:</strong>
            <input type="password" name="newPassword" id="newPassword" value="" required>
            <strong class="clear"></strong></label>
        <label><strong>Correo Electrónico: </strong>
            <input type="text" name="email" id="email" value="<?php echo $email; ?>"required>
            <strong class="clear"></strong></label>
        <div class="btns"><input class="input2" type="submit" value="Enviar"></div>
    </fieldset>

    <br><br>

    <fieldset><legend class="bold">Datos Optativos:</legend>
        <label><strong>Nombre: </strong>
            <input type="text" name="name" id="name" value="<?php echo $name; ?>">
            <strong class="clear"></strong></label>
        <label><strong>Apellidos: </strong>
            <input type="text" name="last_name" id="last_name" value="<?php echo $last_name; ?>">
            <strong class="clear"></strong></label>
        <label><strong>DNI: </strong>
            <input type="text" name="dni" id="dni" value="<?php echo $dni; ?>">
            <strong class="clear"></strong></label>
        <label><strong>Dirección: </strong>
            <input type="text" name="address" id="address" value="<?php echo $address; ?>">
            <strong class="clear"></strong></label>
        <label><strong>CP: </strong>
            <input type="text" name="zip" id="zip" value="<?php echo $zip; ?>">
            <strong class="clear"></strong></label>
        <label><strong>Población: </strong>
            <input type="text" name="town" id="town" value="<?php echo $town; ?>">
            <strong class="clear"></strong></label>
        <label><strong>Provincia: </strong>
            <input type="text" name="province" id="province" value="<?php echo $province; ?>">
            <strong class="clear"></strong></label>
        <label><strong>Sexo:</strong>
            <input class="correction2" type="radio" name="sex" value="<?php echo $sex; ?>" id="sex">Hombre<br>
            <input class="correction2" type="radio" name="sex" value="<?php echo $sex; ?>" id="sex">Mujer<br>
            <strong class="clear"></strong></label>
        <label><strong>Teléfono: </strong>
            <input type="text" name="phone" id="phone" value="<?php echo $phone; ?>">
            <strong class="clear"></strong></label>
        <label><strong>Fecha de nacimiento: </strong>
            <input type="text" name="birth_date" id="birth_date" placeholder="(AAAA/MM/DD)" value="<?php echo $birth_date; ?>">
            <strong class="clear"></strong></label>
        <div class="btns"><input class="input2" type="submit" value="Enviar"></div>
    </fieldset>
</form>
</div>
<div class="clear"></div>